package cn.edu.zjgsu.ito.util;

import java.text.SimpleDateFormat;
import java.util.Date;

public class GetTimeUtil
{
	public static final GetTimeUtil dao =new GetTimeUtil();
	
	SimpleDateFormat df = new SimpleDateFormat("yyyy-MM-dd-HH-mm-ss");//设置日期格式
	
	SimpleDateFormat df2 = new SimpleDateFormat("yyyy-MM-dd");
    
    SimpleDateFormat df3 = new SimpleDateFormat("yyyy/MM/dd");
	
	public String getTime()
	{
		Date date =new Date();// new Date()为获取当前系统时间
		String time=df.format(date);
		return time;
	}
	
	public String getTime2()
	{
		Date date =new Date();// new Date()为获取当前系统时间
		String time=df2.format(date);
		return time;
	}
    
    public String getTime3()
	{
		Date date =new Date();// new Date()为获取当前系统时间
		String time=df3.format(date);
		return time;
	}

}
